def enumPriority(**enums):
    return type('EnumPriority', (), enums)

Priority = enumPriority(    debug='debug',
                            info='info',
                            notice='notice',
                            warning='warn',
                            err='err',
                            crit='crit',
                            alert='alert',
                            emerg='emerg',
                            none='none',
                            all='*'        )

PriorityDict = {'debug':Priority.debug,
                'info':Priority.info,
                'notice':Priority.notice,
                'warn':Priority.warning,
                'err':Priority.err,
                'crit':Priority.crit,
                'alert':Priority.alert,
                'emerg':Priority.emerg,
                'none':Priority.none,
                '*':Priority.all        }
